package com.hdl.school.bean;

import org.xutils.db.annotation.Column;
import org.xutils.db.annotation.Table;

import java.sql.Date;

@Table(name="device_log")
public class DeviceLog {
    @Column(name = "id", isId = true)
    private int id;

    //事件类型
    @Column(name = "event_type")
    private int eventType;

    @Column(name = "source_type")
    private int sourceType;

    @Column(name = "desc")
    private String desc;

    @Column(name = "create_user")
    private int createUser;

    @Column(name = "create_time")
    private Date createTime;

    public DeviceLog(){

    }

    public DeviceLog(int eventType, int sourceType, String desc, int createUser) {
        this.eventType = eventType;
        this.sourceType = sourceType;
        this.desc = desc;
        this.createUser = createUser;
        this.createTime=new Date(System.currentTimeMillis());
    }

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public int getEventType() {
        return eventType;
    }

    public void setEventType(int eventType) {
        this.eventType = eventType;
    }

    public int getSourceType() {
        return sourceType;
    }

    public void setSourceType(int sourceType) {
        this.sourceType = sourceType;
    }

    public String getDesc() {
        return desc;
    }

    public void setDesc(String desc) {
        this.desc = desc;
    }

    public int getCreateUser() {
        return createUser;
    }

    public void setCreateUser(int createUser) {
        this.createUser = createUser;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }
}
